package com.newtouch.bxzs.common.base.model;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 个人客户信息实体类
 *
 * <p>
 * <b>History:</b>
 * <table border="1">
 * <tr>
 * <th>Date</th>
 * <th>Operator</th>
 * <th>Memo</th>
 * </tr>
 * <tr>
 * <td>2020/12/21 14:06</td>
 * <td>lingshouyi</td>
 * <td>Create</td>
 * </tr>
 * </table>
 *
 * @author lingshouyi
 * @version 1.0.0
 * @since 1.0.0
 */
@ApiModel(value = "Customer", description = "个人客户实体类")
@Data
@TableName(value = "ASSISTANT_CUSTOMER")
public class PersonalCustomer {
	/** 主键CUSTOMER_ID */
	@TableId(value = "CUSTOMER_ID", type = IdType.ASSIGN_UUID)
	private String customerId;
	
	/** 姓名 */
	@TableField(value = "CUSTOMER_NAME")
	private String customerName;
	
	/** 性别 */
	@TableField(value = "CUSTOMER_SEX")
	private String customerSex;
	
	/** 手机号 */
	@TableField(value = "CUSTOMER_PHONE")
	private String customerPhone;
	
	/** 电话 */
	@TableField(value = "CUSTOMER_TELEPHONE")
	private String customerTelephone;
	
	/** 证件类型 */
	@TableField(value = "CUSTOMER_CERTIFICATE_TYPE")
	private String customerCertificateType;
	
	/** 证件号 */
	@TableField(value = "CUSTOMER_CERTIFICATE_NUMBER")
	private String customerCertificateNumber;
	
	/** 客户姓名全拼 */
	@TableField(value = "CUSTOMER_NAME_FULL_SPELLING")
	private String customerNameFullSpelling;
	
	/** 生日 */
	@TableField(value = "CUSTOMER_BIRTHDAY")
	@JsonFormat(pattern = "yyyy-MM-dd", timezone = "CST")
	@DateTimeFormat(pattern = "yyyy-MM-dd")
	private Date customerBirthDay;
	
	/** 职业 */
	@TableField(value = "CUSTOMER_OCCUPATION")
	private String customerOccupation;
	
	/** 家庭地址 */
	@TableField(value = "CUSTOMER_FAMILY_ADDRESS")
	private String customerFamilyAddress;
	
	/** 是否参加社保 */
	@TableField(value = "IS_SOCIAL_INSURANCE")
	private String socialInsurance;
	
	/** 公司名称 */
	@TableField(value = "CUSTOMER_COMPANY_NAME")
	private String customerCompanyName;
	
	/** 公司地址 */
	@TableField(value = "CUSTOMER_COMPANY_ADDRESS")
	private String customerCompanyAddress;
	
	/** 职位 */
	@TableField(value = "CUSTOMER_POSITION")
	private String customerPosition;
	
	/** 个人年收 */
	@TableField(value = "CUSTOMER_ANNUAL_INCOME")
	private BigDecimal customerAnnualIncome;
	
	/** 婚姻状况 */
	@TableField(value = "CUSTOMER_MARRY_STATUS")
	private String customerMarryStatus;
	
	/** 子女状况 */
	@TableField(value = "CUSTOMER_CHILD_STATUS")
	private String customerChildStatus;
	
	/** 爱好 */
	@TableField(value = "CUSTOMER_HOBBY")
	private String customerHobby;
	
	/** 客户标识 */
	@TableField(value = "CUSTOMER_LABEL")
	private String customerLabel;
	
	/** 所属用户 */
	@TableField(value = "USER_JOB_NUMBER")
	private String userJobNumber;
	
	/** 创建人ID */
	@TableField(value = "CREATE_USER_ID")
	private String createUserId;
	
	/** 创建时间 */
	@TableField(value = "CREATE_TIME")
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "CST")
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date createTime;
	
	/** 修改人ID */
	@TableField(value = "UPDATE_USER_ID")
	private String updateUserId;
	
	/** 修改时间 */
	@TableField(value = "UPDATE_TIME")
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "CST")
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date updateTime;
	
	/** 备注 */
	@TableField(value = "MEMO")
	private String memo;
	
	/** 删除状态 */
	@TableField(value = "IS_DELETE")
	@TableLogic(value = "0", delval = "1")
	private Boolean deleteFlag = false;

	public void setDefaultValue(String customerLabel,String userJobNumber){
		this.customerLabel = customerLabel;
		this.userJobNumber = userJobNumber;
	}

}
